package com.aistar.order.config;


import com.aistar.order.util.MailUtils;
import com.aistar.order.util.SMSCodes;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author success
 * @version 1.0
 * @description:本类用来演示:相当于spring-bean.xml - >  管理一些第三方的bean
 * @date 2019/6/26 0026
 */
@Configuration
public class AppBeanConfigs {
    /**
     *springboot中可以通过代码的方式来注册组件 - IdWorker
     * <bean id="idWorker" class="com.aistar.util.IdWorker"></>
     */
    @Bean
    public SMSCodes smsCodes(){
        return new SMSCodes();
    }

    @Bean
    public MailUtils mailUtils() {return new MailUtils(); }
}
